import re
str7 = "What time is it now? It's six p.m now."
# 查询以字母i开头的完整单词
print(re.findall('\\bi.+?\\b', str7))
# 查询以字母i开头的字符串
print(re.findall('\\bi.+\\b', str7))
# 查询所有单词
print(re.findall(r'\b\w.+?\b', str7))

str8 = 'IP 地址：192.168.1.102，网关：192.168.1.1'
print(re.findall(r'\d+\.\d+\.\d+\.\d+', str8))